package com.yanqu.road.entity.activity.memorypieces;

import com.yanqu.road.entity.DataObject;
import com.yanqu.road.entity.FieldTypeAnnotation;
import com.yanqu.road.entity.DataStatus;

import java.util.List;

@FieldTypeAnnotation(tableName = "t_u_activity_memory_pieces_progress")
public class MemoryPiecesProgress extends DataObject {

    @FieldTypeAnnotation(update = true, desc = "角色id")
    private long userId;

    @FieldTypeAnnotation(select = true, update = true, desc = "活动id")
    private int activityId;

    @FieldTypeAnnotation(desc = "拼图id")
    private int piecesId;

    @FieldTypeAnnotation(desc = "已点亮的拼图碎片(索引)")
    private List<Integer> lightPieces;

    public MemoryPiecesProgress() {

    }

    public long getUserId() {
        return userId;
    }

    public void setUserId(long userId) {
        if (this.userId != userId) {
            this.userId = userId;
            setOp(DataStatus.Update);
        }
    }

    public int getActivityId() {
        return activityId;
    }

    public void setActivityId(int activityId) {
        if (this.activityId != activityId) {
            this.activityId = activityId;
            setOp(DataStatus.Update);
        }
    }

    public int getPiecesId() {
        return piecesId;
    }

    public void setPiecesId(int piecesId) {
        if (this.piecesId != piecesId) {
            this.piecesId = piecesId;
            setOp(DataStatus.Update);
        }
    }

    public List<Integer> getLightPieces() {
        return lightPieces;
    }

    public void setLightPieces(List<Integer> lightPieces) {
        this.lightPieces = lightPieces;
        setOp(DataStatus.Update);
    }
}
